|
2020-2021 Sunseeker Telemetry and Lighting System
|
#include "driverlib.h"Go to the source code of this file.
Macros | |
| #define | SLAVE_ADDRESS 0x48 |
| #define | RXCOUNT 0x05 |
Functions | |
| void | main () |
| void | USCI_B0_ISR (void) |
Variables | |
| unsigned char | receiveBuffer [10] |
| unsigned char * | receiveBufferPointer |
| unsigned char | receiveCount = 0 |
| #define RXCOUNT 0x05 |
Definition at line 72 of file usci_b_i2c_ex4_masterRxMultiple.c.
| #define SLAVE_ADDRESS 0x48 |
This example shows how to configure the I2C module as a master for multi-byte reception with help of interrupts. The address of the slave module that the master communicating with also set in this example. This example uses the interrupt driven mode to receive data.
This example uses the following peripherals and I/O signals. You must review these and change as needed for your own board:
This example uses the following interrupt handlers. To use this example in your own application you must add these interrupt handlers to your vector table.
Definition at line 66 of file usci_b_i2c_ex4_masterRxMultiple.c.
| void main | ( | void | ) |
Definition at line 79 of file usci_b_i2c_ex4_masterRxMultiple.c.
References __no_operation(), param, receiveBuffer, receiveBufferPointer, receiveCount, RXCOUNT, and SLAVE_ADDRESS.
| void USCI_B0_ISR | ( | void | ) |
Definition at line 143 of file usci_b_i2c_ex4_masterRxMultiple.c.
References __bic_SR_register_on_exit(), receiveBufferPointer, and receiveCount.
| unsigned char receiveBuffer[10] |
Definition at line 74 of file usci_b_i2c_ex4_masterRxMultiple.c.
Referenced by main().
| unsigned char* receiveBufferPointer |
Definition at line 76 of file usci_b_i2c_ex4_masterRxMultiple.c.
Referenced by main(), and USCI_B0_ISR().
| unsigned char receiveCount = 0 |
Definition at line 77 of file usci_b_i2c_ex4_masterRxMultiple.c.
Referenced by main(), and USCI_B0_ISR().